package com.lxy.cloud.order.controller;

import com.springcloud.model.User;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class IndexController {

    @RequestMapping("/hello")
    public String hello() {
        return "order server";
    }

    @RequestMapping("/get")
    public String get(@RequestBody User user) {
        System.out.println("username = " + user.getName());
        return "get user server";
    }
}